/*
 *
 * Copyright (C) 2012 Walter Lütgenau
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 * 
 *      http://www.apache.org/licenses/LICENSE-2.0
 * 
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 * 
 */
package offset.nodes.client.dialog.newnode.model;

import java.util.ResourceBundle;

/**
 *
 * @author Walter Lütgenau
 */
public class ObjectType {
    private String name;
    private String description;
    private Step[] steps;
    ResourceBundle bundle;
    private Processor processor;
    
    /** Creates a new instance of ObjectType */
    public ObjectType(ResourceBundle bundle) {
        this.bundle = bundle;
    }
    
    public ObjectType(ResourceBundle bundle, String name, String description, Step[] steps, Processor processor) {
        this.bundle = bundle;
        this.name = name;
        this.description = description;
        this.steps = steps;
        this.setProcessor(processor);
        processor.setObjectType(this);
    }

    public String getName() {
        return bundle.getString(name);
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getDescription() {
        return bundle.getString(description);
    }

    public void setDescription(String description) {
        this.description = description;
    }

    public Step[] getSteps() {
        return steps;
    }

    public void setSteps(Step[] steps) {
        this.steps = steps;
    }

    public Processor getProcessor() {
        return processor;
    }

    public void setProcessor(Processor processor) {
        this.processor = processor;
    }
    
}
